<%@page contentType="text/html"%>
<%@page pageEncoding="UTF-8"%>

<%@ taglib uri="http://struts.apache.org/tags-bean" prefix="bean" %>
<%@ taglib uri="http://struts.apache.org/tags-html" prefix="html" %>
<%@ taglib uri="http://struts.apache.org/tags-logic" prefix="logic" %>

<html:html lang="true">
    <head>
        <meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
        <title>Blue Pumpkin Administrator</title>
        <script type="text/javascript" src="Admin/Files/jquery-1.3.2.pack.js"></script>
        <script type="text/javascript" src="Admin/Files/jquery-ui-1.7.2.custom.min.js"></script>
        <script type="text/javascript" src="Admin/Files/timepicker.js"></script>
	<script type="text/javascript" src="Admin/Files/ajax-upload.js"></script>
        <script type="text/javascript" src="Admin/Files/script.js"></script>
        <script type="text/javascript" src="Admin/Files/jquery.autocomplete.js"></script>
        <script type="text/javascript" src="Admin/Files/jquery.tablednd_0_5.js"></script>
        <link rel="stylesheet" type="text/css" href="Admin/Files/template.css" />
        <link rel="stylesheet" type="text/css" href="Admin/Files/jquery.autocomplete.css" />
        <link rel="stylesheet" type="text/css" href="Admin/Files/jquery-ui-1.8.1.custom.css" />
        <html:base/>
        <script>
            $(function(){
                $('input[name="btnSubmit"]').click(function(){
                    var error = '';
                    var username = $('input[name="username"]').val();
                    var password = $('input[name="password"]').val();
                    if (username.length == 0)
                        error += '<div style="color:red;">Please enter the user name.</div>';
                    if (password.length == 0)
                        error += '<div style="color:red;">Please enter the password.</div>';
                    if (error.length > 0) {
                        $('#error-holder').html(error);
                        return false;
                    }
                });
            });
        </script>
    </head>
    <body id="login"  class="theme3">
        
        <logic:notPresent name="org.apache.struts.action.MESSAGE" scope="application">
            <div  style="color: red">
                ERROR:  Application resources not loaded -- check servlet container
                logs for error messages.
            </div>
        </logic:notPresent>
        
        
    <div id="ap-login">
        <div id="content-box">
            <div class="padding">
                <div id="element-box" class="login">
                    <h3>Blue Pumpkin Login</h3>
                    <div>
                        <div id="section-box" class="panel">
                            <div class="jpane-slider">
                                <html:form action="/LoginAdmin" method="post" style="clear:both;">
                                    <p id="form-login-username">
                                        <label for="modlgn_username"><strong>User name</strong></label>
                                        <html:text property="username" styleClass="inputbox" size="15"></html:text>
                                        
                                    </p>
                                    <p id="form-login-password">
                                        <label for="modlgn_passwd"><strong>Password</strong></label>
                                        <html:password property="password" styleClass="inputbox" size="15"></html:password>
                                    </p>
                                    
                                    <div class="button_holder">
                                        <div class="button1">
                                            <div class="next">
                                                <html:submit property="btnSubmit"></html:submit>
                                            </div>
                                        </div>
                                    </div>
                                    
                                    <div class="clr"></div>
                                </html:form>
                                <div class="clr"></div>
                                <div id="error-holder">${error}</div>
                            </div>
                        </div>
                        <p class="login-desc" id="result">Use a valid email and password to gain access to the Administrator Back-end.</p>
                        <p class="home-page">
                            <a href="">Return to site Home Page</a>
                        </p>
                        <div id="lock"></div>
                        <div class="clear"></div>
                    </div>
                </div>
                <noscript>
                    Warning! JavaScript must be enabled for proper operation of the Administrator back-end.
                </noscript>
                <div class="clr"></div>
            </div>
        </div>
    </div>

    


    </body>
</html:html>
